---
layout: docs
page_title: 'nomad config validate command reference'
description: |
  The `nomad config validate` command validates Nomad configuration files so you can test Nomad configuration without starting the agent.
---

# `nomad config validate` command reference

The `config validate` command performs validation on a set of Nomad
configuration files. This is useful to test the Nomad configuration
without starting the agent.

## Usage

```plaintext
nomad config validate <config_path> [<config_path...>]
```

The `config validate` command requires a path to either a single
configuration file or a directory of configuration files to use for
configuring the Nomad agent. This option can be specified multiple
times. If multiple config files are passed, the values from each will
be merged together. During merging, values from files found later in
the list are merged over values from previously parsed files.

This command cannot operate on partial configuration fragments since
those won't pass the full agent validation. This command does not
require an ACL token.

Returns 0 if the configuration is valid, or 1 if there are problems.

## Examples

Validate a configuration file:

```shell-session
$ nomad config validate ./nomad.hcl
Configuration is valid!
```

Validate a directory of configuration files:

```shell-session
$ nomad config validate /etc/nomad.d
Configuration is valid!
```

## General options

@include 'general_options.mdx'
